function q = ElnpmuLambda(mix)

% E[ln p(mu, Lambda)]

[K D] = size(mix.centres);

% priors
m0 = mix.varprior.m0;
b0 = mix.varprior.b0;
W0 = mix.varprior.W0;
v0 = mix.varprior.v0;

% posteriors
m = mix.varposterior.m;
b = mix.varposterior.b;
W = mix.varposterior.W;
v = mix.varposterior.v;

% expectation of logdet
ElndetLambda = mix.varposterior.ElndetLambda;

q_a = 0;
for k = 1:K
    q_a = q_a + D*log(b0/(2*pi)) + ElndetLambda(k) - D*b0/b(k) ...
                - b0*v(k)*(m(k, :)-m0)*W(:, :, k)*(m(k, :)-m0)';
end
q_a = 0.5*q_a;
% simplifying assumption made by first addition
q_b = K*wishartln_denom(W0, v0) + 0.5*sum((v0-D-1).*ElndetLambda);
for k = 1:K
    q_b = q_b - 0.5*v(k)*trace(inv(W0)*W(:, :, k));
end
q = q_a + q_b;
